
<div class="titlebar">
    <div class="fn-left"><i class="iconfont icon-line-chart_icon"></i> 数据统计</div>
    <div class="fn-right">
        <form class="input-group" id="form" action="{:url('info.index/index',['types' => 0])}">
            <input placeholder="开始时间" class="input w100 ui-date" type="text" name="starttime" readonly autocomplete="false" value="{$starttime}"/>
            <input placeholder="结束时间" class="input w100 ui-date" type="text" name="endtime" readonly autocomplete="false" value="{$endtime}"/>
            <input type="submit" value="搜索" class="button button-blue" />
        </form>
    </div>
    <div class="fn-right button-group">
        <a href="{:url('info.index/index',['time' => 1,'types'=>0])}" class="button {$time==1?'button-violet':''}">今日</a>
        <a href="{:url('info.index/index',['time' => 2,'types'=>0])}" class="button {$time==2?'button-violet':''}">昨日</a>
        <a href="{:url('info.index/index',['time' => 30,'types'=>0])}" class="button {$time==30?'button-violet':''}"">本月</a>
        <a href="{:url('info.index/index',['time' => 60,'types'=>0])}" class="button {$time==60?'button-violet':''}"">上月</a>
    </div>
</div>
<div class="cards">
    <div class="card green">
        <div class="fn-left"><i class="iconfont icon-my_icon"></i></div>
        <div class="fn-right fn-tar"><div class="num">{$top_num}</div><div class="text">置顶数量</div></div>
    </div>
    <div class="card yellow">
        <div class="fn-left"><i class="iconfont icon-renminbi1688"></i></div>
        <div class="fn-right fn-tar"><div class="num">{$lock_num}</div><div class="text">锁定数量</div></div>
    </div>
    <div class="card blue">
        <div class="fn-left"><i class="iconfont icon-renminbi1688"></i></div>
        <div class="fn-right fn-tar"><div class="num">{$views_num}</div><div class="text">总阅读数</div></div>
    </div>
</div>
<div class="titlebar">
    <div class="fn-left"><i class="iconfont icon-text_icon"></i>同城信息</div>
    <div class="fn-right">
        <a href="{:url('info.index/index',['types'=>0,'time'=>$time])}" class="button{if $types == 0} button-green{/if}">正常</a>
        <a href="{:url('info.index/index',['types'=>1,'time'=>$time])}" class="button{if $types == 1} button-green{/if}">锁定</a>
    </div>
</div>
<table class="pure-table">
    <thead>
        <tr>
            <th class="w60 fn-tac">类型</th> 
            <th>内容</th>
            <th class="w100 fn-tac">时间</th>        
            <th class="w60 fn-tac">置顶</th> 
            <th class="w80 fn-tac">锁定</th>
            <th class="w80 fn-tac">阅读数</th>
            <th class="w140">发布时间</th>
            <th class="w120 fn-tac">操作</th>
        </tr>
    </thead>
    <tbody>
        {foreach $lists as $vo}
        <tr>
            <td class="fn-tac">
                {if $vo.is_get && $vo.price > 0}
                    <span class="badge bg-red">￥{$vo.price}</span>
                {else}
                    <span class="badge">免费</span>
                {/if}
            </td>
            <td>
                {if $vo.is_pay}<span class="badge bg-red">付费</span>{else}<span class="badge">普通</span>{/if}&nbsp;
                {if $vo.images}<span class="badge bg-blue">图</span>{/if}
                <a href="{:url('info.index/reply',['id'=>$vo.id])}">{$vo.themes}</a>
            </td>
            <td class="fn-tac">{$vo.howday}</td>
            <td class="fn-tac">
                <a class="isLock" url="{:url('info.index/istop',['id'=>$vo.id])}" href="javascript:;" title="置顶/普通">
                    {if $vo.is_top}
                        <span class="badge bg-red">置顶{if $vo.topday > 0}({$vo.topday}天){/if}</span>
                    {else}
                        <span class="badge">置顶</span>
                    {/if}
                </a>
            </td>  
            <td class="fn-tac">
                <a class="isLock" url="{:url('info.index/islock',['id'=>$vo.id])}" href="javascript:;" title="锁定/解锁">
                    {if $vo.is_lock}<span class="badge bg-red">锁定</span>{else}<span class="badge">锁定</span>{/if}
                </a>
            </td>
            <td class="fn-tac">{$vo.views}</td>
            <td>{$vo.create_time|date='Y-m-d H:i'}</td>
            <td class="fn-tac"><a class="button isDel" url="{:url('info.index/delete',['id'=>$vo.id])}" href="javascript:;" title="删除"><i class="iconfont icon-lajixiang"></i>删除</a></td>
        </tr>
        {/foreach}
    </tbody>
</table>
{$lists|raw}
<script type="text/javascript">
Do('base','form','layer','tip','date', function () {
    $('#form').isForm({types:1});
    $('.isDel').isDel();
    $('.isLock').actUrl()
})
</script>